package com.dly.hope.repository;

import com.dly.hope.modle.ShowPraise;
import org.springframework.data.jpa.repository.JpaRepository;

import java.util.List;
import java.util.Optional;

public interface ShowPraiseRepository extends JpaRepository<ShowPraise, String> {

    Optional<ShowPraise> findTopByUserIdAndShowIdAndDataStatus(String userId, String showId, Integer state);

    Optional<ShowPraise> findTopByUserIdAndShowId(String userId, String showId);

    List<ShowPraise> findAllByShowIdInAndDataStatus(List<String> showIds, Integer state);
}
